package battlecruiser.ship.placement.rules;

import battlecruiser.ship.placement.ship.ShipType;

import java.util.Map;
import java.util.TreeMap;

/**
 * @author tymoshya
 * @since 18.06.12
 */
// TODO ensure it is singleton (by Spring)
public class BasicShipPlacingRules implements ShipPlacingRules {

    private Map<ShipType, Integer> rules;

    public BasicShipPlacingRules() {
        rules = new TreeMap<ShipType, Integer>();
        rules.put(ShipType.FOUR_DECK, 1);
        rules.put(ShipType.THREE_DECK, 2);
        rules.put(ShipType.TWO_DECK, 3);
        rules.put(ShipType.ONE_DECK, 4);
    }


    public Map<ShipType, Integer> getRules() {
        return rules;
    }
}
